﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="BankListSelect.aspx.cs"
    Inherits="Thksoft.Funds.BankListSelect" %>

<!DOCTYPE html>
<html class="L_UI">
<head id="Head1" runat="server">
    <title>银行流水记录明细</title>
    <link href="../CSS/Main.css" rel="stylesheet" type="text/css" />
    <link href="../UserCotrols/My97DatePicker/skin/WdatePicker.css" rel="stylesheet"
        type="text/css" />
    <script src="../UserCotrols/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
    <script src="../Scripts/jquery-1.7.min.js" type="text/javascript"></script>
    <script type="text/javascript">

        var option = {};
        option.Area = ["880px", "460px"];
        /*option.Callback = function (index, layero) {
            //刷新页面
            location.href = location.href;
        };*/

        option.Title = "1";
        option.CancelCallback = function (index, layero) {
            //刷新页面
            //location.href = location.href;
            document.getElementById("btnSelect").click();
            //$("#btnQuery").click();
        };

        function FORM_INSERT() {

            option.Url = "../Funds/BankListEdit.aspx";
            option.Title = "新增银行流水";
            top.MessageBox.Load(option);
        }
        function FORM_EDIT(id) {
            option.Url = "../Funds/BankListEdit.aspx?ID=" + id;
            option.Title = "编辑银行流水";
            top.MessageBox.Load(option);
        }

        function FORM_UPDATE() {
            //top.console.log($('#form1 input:checkbox:checked'));
            var bbq = $('#form1 input:checkbox:checked').length;
            if (bbq == 0) {
                top.MessageBox.Alert("请选择需要修改的行");
                return;
            }
            if (bbq > 1) {
                top.MessageBox.Alert("修改不能多选");
                return;
            }
            var option = {};
            option.Type = "confirm";
            option.YesCallback = function (index, dom) {
                top.layer.close(index);
                document.getElementById("btnEdit").click();
            };
            option.Msg = "确定修改?";
            top.MessageBox.Show(option);
        }
    </script>
</head>
<body>
    <form id="form1" runat="server">
        <div class="Window" style="min-width: 1100px;">
            <div class="Header" style="height: 79px;">
                <table border="0" cellpadding="0" cellspacing="0" width="100%" class="table">
                    <tr>
                        <td style="width: 7%; text-align: right; padding-right: 5px;">公&nbsp;&nbsp;&nbsp;&nbsp;司：
                        </td>
                        <td style="width: 20%; text-align: left; padding-left: 10px;">
                            <uc2:CtrlCompany runat="server" ID="FORM_COMPANY_ID" />
                        </td>
                        <td style="width: 7%; text-align: right; padding-right: 5px;">录入类型：
                        </td>
                        <td style="width: 15%; text-align: left; padding-left: 10px;">
                            <asp:DropDownList ID="ddlCheckType" runat="server" CssClass="INPUT">
                                <asp:ListItem Value="-1" Selected="True">---请选择---</asp:ListItem>
                                <asp:ListItem Value="0">手动录入</asp:ListItem>
                                <asp:ListItem Value="1">自动获取</asp:ListItem>
                            </asp:DropDownList>
                        </td>
                        <td style="width: 7%; text-align: right; padding-right: 5px;">具体日期：
                        </td>
                        <td style="text-align: left; padding: 5px;">
                            <input id="txtDate" runat="server" class="Wdate INPUT DATE" type="text"
                                onclick=" WdatePicker()" />
                            至
                        <input id="txtEnd" runat="server" class="Wdate INPUT DATE" type="text"
                            onclick="WdatePicker()" />
                        </td>
                    </tr>
                    <tr>
                        <td align="center" colspan="6" >
                            <asp:Button ID="btnSelect" runat="server" Text="查询" CssClass="bt_css_s" OnClick="btnSelect_Click" />&nbsp;
                        <asp:Button ID="btnInsert" runat="server" Text="新增" CssClass="bt_css_s" OnClick="btnInsert_Click" />&nbsp;
                        <input type="button" value="修改" class="bt_css_s" onclick="FORM_UPDATE();" />
                            <asp:Button ID="btnEdit" runat="server" Text="修改" CssClass="hide" OnClick="btnEdit_Click"
                                OnClientClick="return ValidateEdit();" />
                        </td>
                    </tr>
                </table>
            </div>
            <div class="Content" style="top: 80px;">
                <div class="Pg-Content">
                    <style type="text/css">
                        .cont_list.zebra tr td.left {
                            text-align: left;
                            padding-left: 10px;
                            text-indent: 0px;
                        }

                        .cont_list.zebra tr td.right {
                            text-align: right;
                            padding-right: 10px;
                            text-indent: 0px;
                        }
                    </style>
                    <asp:ScriptManager ID="ScriptManagers" runat="server" EnablePageMethods="True" EnableScriptGlobalization="True"
                        EnableScriptLocalization="True">
                    </asp:ScriptManager>
                    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                        <ContentTemplate>
                            <asp:GridView ID="grvShow1" runat="server" AutoGenerateColumns="False" CssClass="cont_list zebra"
                                Width="100%" EmptyDataText="没有查找到您要的数据" AllowSorting="True" OnSorting="grvShow1_Sorting">
                                <Columns>
                                    <asp:TemplateField ItemStyle-Width="50px">
                                        <HeaderTemplate>
                                            <asp:CheckBox ID="chkSelectAll" runat="server" Onclick="GetAllCheckBox(this)" />
                                        </HeaderTemplate>
                                        <ItemTemplate>
                                            <asp:CheckBox ID="chkSelectId" runat="server" ToolTip='<%#Eval("n_detail_listid")%>' />
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                    <asp:BoundField DataField="C_ACCNO1" HeaderText="账号" SortExpression="C_ACCNO1" ItemStyle-CssClass="left" />
                                    <asp:BoundField DataField="c_accno2" HeaderText="对方账号" SortExpression="c_accno2" ItemStyle-CssClass="left" />
                                    <asp:BoundField DataField="C_ACC_NAME1" HeaderText="对方账号名称" SortExpression="C_ACC_NAME1" ItemStyle-CssClass="left" />
                                    <asp:BoundField DataField="cmy_name" HeaderText="公司" SortExpression="cmy_name" ItemStyle-CssClass="left" />
                                    <asp:BoundField DataField="c_name" HeaderText="银行" SortExpression="c_name" ItemStyle-CssClass="left" />
                                    <asp:BoundField DataField="d_trandate" HeaderText="日期" SortExpression="d_trandate"
                                        ItemStyle-Width="80px" />
                                    <asp:TemplateField HeaderText="发生额" SortExpression="n_amt" ItemStyle-CssClass="right">
                                        <ItemTemplate>
                                            <%#Utility.Helper.HtmlHelper.QyFormat(Convert.ToDecimal(Eval("n_amt")),2) %>
                                        </ItemTemplate>
                                    </asp:TemplateField>
                                    <asp:BoundField DataField="n_flag1" HeaderText="借贷标志" SortExpression="n_flag1" ItemStyle-Width="50px" />
                                    <asp:BoundField DataField="C_DET" HeaderText="备注" SortExpression="C_DET" />
                                    <asp:BoundField DataField="C_MESSAGE" HeaderText="摘要" SortExpression="C_MESSAGE" />
                                </Columns>
                            </asp:GridView>
                        </ContentTemplate>
                    </asp:UpdatePanel>
                </div>

                <div class="Pg">
                    <uc1:Pagination ID="PageIng" runat="server" OnDataBinding="PageIng_DataBinding" Visible="false" />
                </div>
            </div>
        </div>
    </form>
</body>
</html>